@extends("/main_template",menu="index")
@import com.mgfireworks.mgplatform.mgshop.model.*
@args List<Product> productList
<!--
      	轮播广告
      -->
<div id="slider" class="mui-slider" >
	<div class="mui-slider-group mui-slider-loop">
		<!-- 额外增加的一个节点(循环轮播：第一个节点是最后一张轮播) -->
		<div class="mui-slider-item mui-slider-item-duplicate">
			<a href="p/01.html">
				<img src="static/img/ad2.jpg">
			</a>
		</div>
		<!-- 第一张 -->
		<div class="mui-slider-item">
			<a href="p/01.html">
				<img src="static/img/ad.jpg">
			</a>
		</div>
		<!-- 第二张 -->
		<div class="mui-slider-item">
			<a href="p/01.html">
				<img src="static/img/ad2.jpg">
			</a>
		</div>
		<!-- 额外增加的一个节点(循环轮播：最后一个节点是第一张轮播) -->
		<div class="mui-slider-item mui-slider-item-duplicate">
			<a href="p/01.html">
				<img src="static/img/ad.jpg">
			</a>
		</div>
	</div>
	<div class="mui-slider-indicator">
		<div class="mui-indicator mui-active"></div>
		<div class="mui-indicator"></div>
	</div>
</div>
<!--
 	通知、新闻
-->
<ul class="news-list mui-row">
	<li class="mui-col-xs-12 mui-ellipsis">
           <a href="news.html">民生保障不是“清谈馆” 办好实事方能得民心,办好实事方能得民心111</a>
    </li>
    <li class="mui-col-xs-12 mui-ellipsis">
           <a href="news.html">1111念念不忘棚户区改造，总理走过的地方说过的话</a>
    </li>
</ul>
<script id="jsTemplateRecommends" url="@url("/product/recommends.json")" type="text/html">
{{each data p}}
    <div class="tuijian mui-card">
        <a href="p/{{p.stockId}}.html" class="mui-card-header mui-card-media"
		style="height:50vw;background-image:url(@url("{{p.mainImg}}"))"></a>
        <div class="mui-card-content">
            <div class="mui-card-content-inner">
                <p>类别:{{p.cateName}},品牌:{{p.bandName}}</p>
                <p>规格:，价格:{{p.price}}</p>
                <p style="color: #333;">{{p.description}}</p>
            </div>
        </div>
    </div>
{{/each}}
</script>
<div>暂无产品</div>
<div class="scroll-fix40"></div>
@section(script){
<script type="text/javascript">
	app.index.onUserInfoLoad(function(){
		//取推荐产品列表
		util.el.templateLoad("jsTemplateRecommends");
	})
</script>
}